﻿@model IEnumerable<FCNS.ERP.Models.ErpOrderFoodIO>

@{
    ViewBag.Title = "待处理菜品";
    Layout = "~/Views/Food/_LayoutKitchen.cshtml";
}

<table class="table">
    <tr>
        <th>
            @Html.DisplayNameFor(model => model.ProductId)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.Count)
        </th>
        <th>
            @Html.DisplayNameFor(model => model.RelatedOrderNO)
        </th>
        <th></th>
    </tr>

    @foreach (var item in Model)
    {
        <tr>
            <td>
                @Html.DisplayFor(modelItem => item.Product.Name)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.Count)
            </td>
            <td>
                @Html.DisplayFor(modelItem => item.RelatedOrderNO)
            </td>
            <td>
@{
    if (item.Status == FCNS.ERP.Models.ErpOrderFoodIO.EnumOrderFoodIOstatus.下单)
    {
                    <a href="FoodCookingChange?ioId=@item.Id&status=1">烹饪</a>
    }
    else if (item.Status == FCNS.ERP.Models.ErpOrderFoodIO.EnumOrderFoodIOstatus.烹饪)
    {
        <a href="FoodCookingChange?ioId=@item.Id&status=2">上菜</a>
                }
    }
            </td>
        </tr>
    }

</table>
